package com.wk.warehouse.mapper;

import com.wk.warehouse.entity.InStore;
import com.wk.warehouse.entity.Purchase;

import java.util.HashMap;
import java.util.List;

public interface PurchaseMapper {

	/**
	 * 查询满足搜索条件的数据条数
	 */
	public int selectCount(Purchase purchase);
	
	/**
	 * 分页查询的数据
	 */
	public List<Purchase> purchasePageQuery(HashMap<String, Object> map);

	/**
	 * 修改入库状态为已入库
	 */
	public int updateInState(int buyId);

	/**
	 * 生成入库单
	 */
	public int addInWarehouseRecord(InStore inStore);
	
	/**
	 * 更新采购单
	 */
	public int updatePurchase(Purchase purchase);
	
	/**
	 * 添加新的采购单
	 */
	public int addPurchase(Purchase purchase);

	/**
	 * 删除采购单
	 */
	public int deletePurchase(int buyId);
	
}
